<?php
/**
 * Created by PhpStorm.
 * User: Mak
 * Date: 2016/3/24 0024
 * Time: 17:14
 */

namespace Admin\Model;
use Think\Model;

class EnInfoModel extends Model{
    protected $tableName = "enrollinfo";


    // 得到所有赛项表中的记录
    public function getList() {
        $ret = $this->order('addtime asc')->select();
        return $ret;
    }

    // 根据赛项编号取得赛项信息
    public function getItem($EnId){
        $condition['enid'] = $EnId;
        $ret = $this->where($condition)->find();
        return $ret;
    }
}